<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <div id="app"></div>
</body>
<script src="./renderer.js"></script>
<script src="./relative.js"></script>
<script src="./index.js"></script>
<script>
  let data = relative({counter:0})
  createApp({
    render:()=>{
      return (h('div',null,[
        h('h2',null,'当前计数:'+data.counter),
        h('button',{'onClick':()=>{
          data.counter++
          console.log(data);
        }},'+1')
      ]))
      
    }
  }).mounted('#app')
  
  
</script>
</html>